using System.Data.Entity.ModelConfiguration;
using ExampleWebApplication.Entities;

namespace ExampleWebApplication.Infraestruture.EntityFramework.EntityTypeConfigurations
{
    public class OrderDetailConfiguration : EntityTypeConfiguration<OrderDetail>
    {
        public OrderDetailConfiguration()
        {
            ToTable("`Order Details`");
            HasKey(entity => new
            {
                entity.ProductID,
                entity.OrderID
            });
        }
    }
}